 
{% extends "player/base.html" %}


{% block main %}

{% if firsthome %}
	<p>Bienvenido a Quien Juega</p>
	<p>Desde aqui podras crear tus partidos, confirmar tu asistencia, etc</p>		
{% endif %}

 

<div class="clear"></div>


<div class="grid_4 alpha omega">
	<h2>Partidos donde juego</h2>
	{% for m_p in matches_player %}
		<p>
			<a href="{% url match_match m_p.match.key.id %}">{{m_p.match}}</a>
			{% if not m_p.confirm %}
				<span>Aun no confirme</span>
			{% else %}
				<span>Ya confirme</span>
			{% endif %}
		</p>
	{% endfor %} 
</div>

<div class="grid_1 alpha omega">&nbsp;</div>
<div class="grid_4 alpha omega">	
	<h2>Administrador</h2>
	<a style="text-decoration:underline" href="{% url player_new_match %}">Nuevo Partido</a>
	{% for match in matches %}
		<p><a href="{% url match_end_match match.key.id %}">{{match}}</a></p>
	{% endfor %}
</div>


<div class="clear"></div>
<h2>Confirmaciones</h2>
{% for m_p in matches_player %}
	<p class="match_name">{{m_p.match}}</p>
	{% with m_p.match.get_confirmations as confirmations %}
		{% if confirmations %}
			<p>{{confirmations|length}} confirmacion(es)</p>			
			{% for con in confirmations %}
				<p style="margin-left:30px">{{con.player.email}}</p>
			{% endfor %}		
		{% else %}
			<p style="margin-left:30px">Sin confirmaciones</p>
		{% endif %}
	{% endwith %}
{% endfor %}

<h2>Resultados</h2>
<h2>Goleadores</h2>

{% endblock %}

{% block sidebar %}
<div class="profile_pict"><img src="{{request.session.current_player.get_pict}}"/></div>
<p class="side_bar_subtitle">Goleadores</p>
<p class="side_bar_subtitle">Los magos</p>
<p class="side_bar_subtitle">Los hachas</p>
<p class="side_bar_subtitle">Turnos disponibles</p>
<p class="side_bar_subtitle">Llamado a la solidaridad!!</p>
{% endblock %}